package com.ruoyi.subject.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.subject.mapper.AccountingMapper;
import com.ruoyi.subject.domain.Accounting;
import com.ruoyi.subject.service.IAccountingService;

/**
 * 科目表Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-03-03
 */
@Service
public class AccountingServiceImpl implements IAccountingService 
{
    @Autowired
    private AccountingMapper accountingMapper;

    /**
     * 查询科目表
     * 
     * @param id 科目表主键
     * @return 科目表
     */
    @Override
    public Accounting selectAccountingById(Long id)
    {
        return accountingMapper.selectAccountingById(id);
    }

    /**
     * 查询科目表列表
     * 
     * @param accounting 科目表
     * @return 科目表
     */
    @Override
    public List<Accounting> selectAccountingList(Accounting accounting)
    {
        return accountingMapper.selectAccountingList(accounting);
    }

    /**
     * 新增科目表
     * 
     * @param accounting 科目表
     * @return 结果
     */
    @Override
    public int insertAccounting(Accounting accounting)
    {
        return accountingMapper.insertAccounting(accounting);
    }

    /**
     * 修改科目表
     * 
     * @param accounting 科目表
     * @return 结果
     */
    @Override
    public int updateAccounting(Accounting accounting)
    {
        return accountingMapper.updateAccounting(accounting);
    }

    /**
     * 批量删除科目表
     * 
     * @param ids 需要删除的科目表主键
     * @return 结果
     */
    @Override
    public int deleteAccountingByIds(Long[] ids)
    {
        return accountingMapper.deleteAccountingByIds(ids);
    }

    /**
     * 删除科目表信息
     * 
     * @param id 科目表主键
     * @return 结果
     */
    @Override
    public int deleteAccountingById(Long id)
    {
        return accountingMapper.deleteAccountingById(id);
    }
}
